package com.example.lib_data.utils

import android.app.Activity
import android.content.Intent
import android.util.Log
import androidx.annotation.AnimRes

/**
 * Activity界面跳转
 */
fun <T:Activity>Activity.navigateTo(
    destination: Class<T>, //目的地的java字节码
    @AnimRes enter: Int = 0, //进入动画
    @AnimRes exit: Int = 0 //退出动画
){
    val intent = Intent(this, destination)
    startActivity(intent)
    overridePendingTransition(enter,exit)
}